package com.example.demo.Entity;

import javax.persistence.Entity;
import javax.persistence.Table;
import javax.persistence.Id;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;

/**
 * @version: V0.3
 * @author: 郑皓杰 吴嘉鑫
 * @className: User
 * @packageName: com.example.demo.Entity
 * @description: 这是user,存储用户名和密码的类
 * @data: 2021-07-15
 **/

@JsonIgnoreProperties({"hibernateLazyInitializer","handler"})//是因为查询到的对象是null值没有获取到，无法反序列化为json 返回到前台
@Entity
@Table(name="user")
public class User {
	/**
	 * 用户用户名
	 */
	@Id
	private String username;
	
	/**
	 * 用户密码
	 */
	private String password;

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	@Override
	public String toString() {
		return "User [username=" + username + ", password=" + password + "]";
	}
	
	

}
